﻿using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;

namespace eLoan.Models
{
    [Table("LoanDeduction")]
    public class LoanDeduction: LoanDeductionFields
    { }

    public class LoanDeductionQueryModel : LoanDeductionFields
    {
        [Display(Name = "Charge Type")]
        [StringLength(100)]
        public string ChargeTypeName { get; set; }
    }

    public class LoanDeductionFields
    {
        [Key]
        [DatabaseGeneratedAttribute(DatabaseGeneratedOption.Identity)]
        [Display(Name = "ID")]
        public int ID { get; set; }

        [Required]
        [Display(Name = "Document No")]
        [StringLength(50)]
        public string DocumentNo { get; set; }

        [Display(Name = "ChargeType")]
        public int ChargeTypeID { get; set; }

        [Display(Name = "Amount")]
        public decimal Amount { get; set; }
    }

}